<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <!-- 1.script.src对引入的文件都会以js的形式运行 -->
    <script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
    <script src="./a.txt"></script>
    <script>
        console.log(a, b);
    </script>

    <!-- 2.引入请求的后台地址 -->
    <script src="http://localhost:3000/index"></script>
    <script>
        console.log(a);
    </script>

    <!-- 3.动态生成script标签 -->

    <script>
        let s = document.createElement('script');
        s.src = 'http://localhost:3000/demo?callback=success';
        document.body.appendChild(s);
        
        function success(res){
            console.log(res);
        }
    </script>
</body>

</html>